﻿using System.Data.Common;
using System.Threading.Tasks;

namespace Solution.Comm.DomainInterfaces
{
    public interface IUnitOfWork
    {
        void Commit();

        Task CommitAsync();

        DbTransaction BeginTransaction();

        /// <summary>
        /// 提交事务
        /// </summary>
        void CommitTransaction();

        /// <summary>
        /// 回滚事务
        /// </summary>
        void RollbackTransaction();
    }
}